import pymysql
import config

conn = pymysql.connect(**config.mysql_option)
cursor = conn.cursor()

cursor.execute(
    ("LOAD DATA LOCAL INFILE '{0}' IGNORE INTO TABLE " +
     "qp.med_flow FIELDS TERMINATED BY ',' ").format("./data.csv")
)
conn.commit()